

package com.hazelcast.internal.metrics;

import java.lang.annotation.Retention;
import java.lang.annotation.Target;

import static java.lang.annotation.ElementType.TYPE;
import static java.lang.annotation.RetentionPolicy.RUNTIME;

/**
 * Annotation for defining class-level {@link MetricTarget} exclusions.
 * The final excluded targets for every metric from the class annotated
 * with this annotation will be the union of the exclusions defined with
 * this annotation and the exclusions defined on the {@link Probe}s.
 *
 * @see Probe#excludedTargets()
 */
@Retention(RUNTIME)
@Target(TYPE)
public @interface ExcludedMetricTargets {

    /**
     * Returns the targets excluded for the class annotated with this
     * annotation. Used for filtering in {@link MetricsPublisher}s.
     *
     * @return the targets excluded for the class
     */
    MetricTarget[] value();
}
